/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package raccoon.suvisa.datos.entities;

import java.io.Serializable;
import java.math.BigInteger;
import javax.persistence.Basic;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.NamedQueries;
import javax.persistence.NamedQuery;
import javax.persistence.Table;

/**
 *
 * @author Laura
 */
@Entity
@Table(name = "THABIENTE", catalog = "", schema = "IS963601")
@NamedQueries({@NamedQuery(name = "Thabiente.findAll", query = "SELECT t FROM Thabiente t"), @NamedQuery(name = "Thabiente.findByNid", query = "SELECT t FROM Thabiente t WHERE t.nid = :nid"), @NamedQuery(name = "Thabiente.findByNombre", query = "SELECT t FROM Thabiente t WHERE t.nombre = :nombre"), @NamedQuery(name = "Thabiente.findByApellido", query = "SELECT t FROM Thabiente t WHERE t.apellido = :apellido"), @NamedQuery(name = "Thabiente.findByEmail", query = "SELECT t FROM Thabiente t WHERE t.email = :email"), @NamedQuery(name = "Thabiente.findByTel", query = "SELECT t FROM Thabiente t WHERE t.tel = :tel"), @NamedQuery(name = "Thabiente.findByDir", query = "SELECT t FROM Thabiente t WHERE t.dir = :dir"), @NamedQuery(name = "Thabiente.findByCupoa", query = "SELECT t FROM Thabiente t WHERE t.cupoa = :cupoa"), @NamedQuery(name = "Thabiente.findByIngresomes", query = "SELECT t FROM Thabiente t WHERE t.ingresomes = :ingresomes"), @NamedQuery(name = "Thabiente.findByAprovado", query = "SELECT t FROM Thabiente t WHERE t.aprovado = :aprovado"), @NamedQuery(name = "Thabiente.findByActivo", query = "SELECT t FROM Thabiente t WHERE t.activo = :activo"), @NamedQuery(name = "Thabiente.findByIdentidad", query = "SELECT t FROM Thabiente t WHERE t.identidad = :identidad")})
public class Thabiente implements Serializable {
    private static final long serialVersionUID = 1L;
    @Id
    @Basic(optional = false)
    @Column(name = "NID", nullable = false, length = 50)
    private String nid;
    @Basic(optional = false)
    @Column(name = "NOMBRE", nullable = false, length = 50)
    private String nombre;
    @Basic(optional = false)
    @Column(name = "APELLIDO", nullable = false, length = 50)
    private String apellido;
    @Basic(optional = false)
    @Column(name = "EMAIL", nullable = false, length = 50)
    private String email;
    @Basic(optional = false)
    @Column(name = "TEL", nullable = false, length = 50)
    private String tel;
    @Basic(optional = false)
    @Column(name = "DIR", nullable = false, length = 50)
    private String dir;
    @Basic(optional = false)
    @Column(name = "CUPOA", nullable = false)
    private double cupoa;
    @Basic(optional = false)
    @Column(name = "INGRESOMES", nullable = false)
    private double ingresomes;
    @Column(name = "APROVADO")
    private Character aprovado;
    @Basic(optional = false)
    @Column(name = "ACTIVO", nullable = false)
    private char activo;
    @Basic(optional = false)
    @Column(name = "IDENTIDAD", nullable = false)
    private BigInteger identidad;

    public Thabiente() {
    }

    public Thabiente(String nid) {
        this.nid = nid;
    }

    public Thabiente(String nid, String nombre, String apellido, String email, String tel, String dir, double cupoa, double ingresomes, char activo, BigInteger identidad) {
        this.nid = nid;
        this.nombre = nombre;
        this.apellido = apellido;
        this.email = email;
        this.tel = tel;
        this.dir = dir;
        this.cupoa = cupoa;
        this.ingresomes = ingresomes;
        this.activo = activo;
        this.identidad = identidad;
    }

    public String getNid() {
        return nid;
    }

    public void setNid(String nid) {
        this.nid = nid;
    }

    public String getNombre() {
        return nombre;
    }

    public void setNombre(String nombre) {
        this.nombre = nombre;
    }

    public String getApellido() {
        return apellido;
    }

    public void setApellido(String apellido) {
        this.apellido = apellido;
    }

    public String getEmail() {
        return email;
    }

    public void setEmail(String email) {
        this.email = email;
    }

    public String getTel() {
        return tel;
    }

    public void setTel(String tel) {
        this.tel = tel;
    }

    public String getDir() {
        return dir;
    }

    public void setDir(String dir) {
        this.dir = dir;
    }

    public double getCupoa() {
        return cupoa;
    }

    public void setCupoa(double cupoa) {
        this.cupoa = cupoa;
    }

    public double getIngresomes() {
        return ingresomes;
    }

    public void setIngresomes(double ingresomes) {
        this.ingresomes = ingresomes;
    }

    public Character getAprovado() {
        return aprovado;
    }

    public void setAprovado(Character aprovado) {
        this.aprovado = aprovado;
    }

    public char getActivo() {
        return activo;
    }

    public void setActivo(char activo) {
        this.activo = activo;
    }

    public BigInteger getIdentidad() {
        return identidad;
    }

    public void setIdentidad(BigInteger identidad) {
        this.identidad = identidad;
    }

    @Override
    public int hashCode() {
        int hash = 0;
        hash += (nid != null ? nid.hashCode() : 0);
        return hash;
    }

    @Override
    public boolean equals(Object object) {
        // TODO: Warning - this method won't work in the case the id fields are not set
        if (!(object instanceof Thabiente)) {
            return false;
        }
        Thabiente other = (Thabiente) object;
        if ((this.nid == null && other.nid != null) || (this.nid != null && !this.nid.equals(other.nid))) {
            return false;
        }
        return true;
    }

    @Override
    public String toString() {
        return "raccoon.suvisa.datos.entities.Thabiente[nid=" + nid + "]";
    }

}
